{% if member or course.coinPrice <= 0 %}
  {% set lessonUrl = path('course_learn', {id:course.id}) ~ '#lesson/' ~ item.id %}
{% else %}
  {% set lessonUrl = previewUrl ~ '?lessonId=' ~ item.id%}
{% endif %}
<!--翟红利 如果课时的类型为【Published】则说明是发布的-->
{% if item.status =='published' %}
<li class="period lesson-item lesson-item-{{ item.id }}" data-id="{{ item.id }}" data-num="{{ loop.index }}">
  {% if item.status == 'published'  and( item.free or  course.buyable|default(true) == true ) %}
    <a
        {% if '0.00' <= 0 %}
            other-datadata="demo"
        {% endif %}
        {% if member or course.coinPrice <= 0 %}
            href="{{ lessonUrl }}" data-toggle="tooltip" data-placement="bottom"
        {% else %}
            href="#modal" data-toggle="modal" data-url="{{ lessonUrl }}"
        {% endif %}
    title="{{ item.title }}">
    {% include 'TopxiaWebBundle:CourseLesson/Part:status-ball.html.twig' %}
    <span class="title">  {% if setting('course.custom_chapter_enabled')|default(true) %} {% endif %}{{ item.title }}</span>
    {% include 'TopxiaWebBundle:CourseLesson/Part:micro-tips.html.twig' %}
    </a>
  {% else %}   
    {% include 'TopxiaWebBundle:CourseLesson/Part:status-ball.html.twig' %}
    <span class="title">{% if setting('course.custom_chapter_enabled')|default(true) %} {% endif %}{{ item.title }}</span>
    <!-- 课时{{ item.number }}： -->
    {% include 'TopxiaWebBundle:CourseLesson/Part:micro-tips.html.twig' %}
  {% endif %}
</li>
{% endif %}
